package club.hicode.daydayup.feign.consumer;

import club.hicode.daydayup.feign.vo.StudentVo;
import cn.hutool.json.JSONUtil;
import com.github.jsonzou.jmockdata.JMockData;
import com.github.jsonzou.jmockdata.TypeReference;
import org.junit.Test;

import java.util.List;
import java.util.Map;

/**
 * 测试输出
 *
 * @author Liu Chunfu
 * @date 2018-07-05 下午3:47
 **/
public class PrintTest {
    @Test
    public void test1() {
        StudentVo mock = JMockData.mock(StudentVo.class);
        System.out.println(JSONUtil.toJsonStr(mock));
    }

    @Test
    public void test2() {
        Map<String, StudentVo> mock = JMockData.mock(new TypeReference<Map<String, StudentVo>>() {
        });
        System.out.println(JSONUtil.toJsonStr(mock));
    }

    @Test
    public void testRequetMap() {
        List<StudentVo> mock = JMockData.mock(new TypeReference<List<StudentVo>>() {
        });
        System.out.println(JSONUtil.toJsonStr(mock));
    }
}
